We can't guarantee that we can load svgs, so
we shouldn't spew criticals when some of our
own resources fail to load due to that reason.
GError **error)
{
GdkPixbuf *pixbuf;
- GdkTexture *texture;
+ GdkTexture *texture = NULL;
pixbuf = gtk_make_symbolic_pixbuf_from_resource (path, width, height, scale, error);
- texture = gdk_texture_new_for_pixbuf (pixbuf);
- g_object_unref (pixbuf);
+ if (pixbuf)
+ {
+ texture = gdk_texture_new_for_pixbuf (pixbuf);
+ g_object_unref (pixbuf);
+ }
return texture;
}